#include<iostream>
#include<cstdlib>
using namespace std;
char *strcat(char *src,char *src1){
	int i,count=0,count1=0;
	char *c=src,*src2;
	while(*c!='\0')
	{
		count++;
		c++;
	}
	c=src1;
	while(*c!='\0')
	{
		count1++;
		c++;
	}
	src2=(char*)malloc(sizeof(char)*(count+count1+1));
	for(i=0;i<count;i++)
	src2[i]=src[i];
	for(i=0;i<count1;i++)
	src2[count+i]=src1[i];
	src2[count+count1]='\0';
	return src2;
}
int main(){
	char *src="hello",*src1="world",*src2;
	src2=strcat(src,src1);
	cout<<src2;
	return 0;
}
